<template>
  <div class="outer">
    <h1>App</h1>
    {{ list }}
    <List @com="com" />
  </div>
</template>

<script>
//js工具包
import _ from "lodash";
import List from "./components/List";

export default {
  name: "App",
  data() {
    return {
      list: [],
    };
  },
  components: {
    List,
  },
  methods: {
    com(value) {
      this.list = _.cloneDeep(value);
      //是否是深拷贝
      console.log(this.list[0] === value[0]);
    },
  },
};
</script>

<style scoped>
/* scoped  当前文件可以使用*/
.outer {
  height: 400px;
  background: yellowgreen;
}
</style>

